<template>
	<div class="quality-document-wrap" @click="buttonClick">
		质量文档库{{documentPageVal}}--{{documentStore.count}}
	</div>
</template>

<script setup>
	import {
		onMounted,
		ref,
		getCurrentInstance
	} from 'vue'
	import { useDocumentStore } from '@/store/documentStore'
	const documentStore = useDocumentStore()
	console.log('documentStore',documentStore.count);
	const documentPageVal = ref('默认值')
	onMounted(() => {
		const {
			proxy
		} = getCurrentInstance()
		proxy.$request.document.page().then(res => {
			console.log('document:page结果', res);
			documentPageVal.value = res
		})
		// console.log('$customMsg',getCurrentInstance());
	})
	function buttonClick() {
	  documentStore.count+=1
	}
</script>

<style>
</style>